import request from '@/utils/request'

// 查询外援列表
export function listHospital(query) {
  return request({
    url: '/manager/hospital/list',
    method: 'get',
    params: query
  })
}

// 查询外援详细
export function getHospital(hospitalID) {
  return request({
    url: '/manager/hospital/' + hospitalID,
    method: 'get'
  })
}

// 新增外援
export function addHospital(data) {
  return request({
    url: '/manager/hospital',
    method: 'post',
    data: data
  })
}

// 修改外援
export function updateHospital(data) {
  return request({
    url: '/manager/hospital',
    method: 'put',
    data: data
  })
}

// 删除外援
export function delHospital(hospitalID) {
  return request({
    url: '/manager/hospital/' + hospitalID,
    method: 'delete'
  })
}

// 导出外援
export function exportHospital(query) {
  return request({
    url: '/manager/hospital/export',
    method: 'get',
    params: query
  })
}